package com.yax.mickey.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.yax.mickey.entity.Feedback;
import com.yax.mickey.entity.Product;
import com.yax.mickey.service.FeedbackService;
import com.yax.mickey.mapper.FeedbackMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
* @author yax
* @description 针对表【feedback(反馈信息表)】的数据库操作Service实现
* @createDate 2024-05-27 09:04:15
*/
@Service
public class FeedbackServiceImpl extends ServiceImpl<FeedbackMapper, Feedback>
    implements FeedbackService{

    @Autowired
    FeedbackMapper feedbackMapper;

    @Override
    public List<Feedback> getAllFeedback() {
        return feedbackMapper.getAllFeedback();
    }

    @Override
    public Integer addFeedback(Feedback feedback) {
        return feedbackMapper.addFeedback(feedback);
    }

    @Override
    public List<Feedback> getFeedbackByUserId(Integer userId) {
        return feedbackMapper.getFeedbackByUserId(userId);
    }

    @Override
    public Feedback getFeedbackByFeedbackId(Integer feedbackId){
        return feedbackMapper.getFeedbackByFeedbackId(feedbackId);
    }

}



